package com.huage.courseplatform.application.model.param;


import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Update;

import javax.validation.constraints.NotEmpty;
import java.io.Serializable;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value="菜单参数",description="菜单参数")
public class MenuPARAM implements Serializable {
    private static final long serialVersionUID = 1L;

    @NotEmpty(message = "id不能为空", groups = Update.class)
    @ApiModelProperty(value = "id(更新可以不传)",required = true)
    private String id;

    @NotEmpty(message = "id不能为空", groups = {Update.class,Insert.class})
    @ApiModelProperty(value = "菜单名",required = true)
    private String name;

    @NotEmpty(message = "跳转路径",groups = {Update.class,Insert.class})
    @ApiModelProperty(value = "跳转路径",required = true)
    private String href;

    @NotEmpty(message = "菜单类型",groups = {Update.class,Insert.class})
    @ApiModelProperty(value = "菜单类型",required = true)
    private String type;

    @ApiModelProperty(value = "排序")
    private Integer sort;

    @ApiModelProperty(value = "菜单父ID")
    private String parentId;

    @ApiModelProperty(value = "备注")
    private String remark;


}
